// vite.config.ts
import { fileURLToPath, URL } from "node:url";
import { createSvgIconsPlugin } from "file:///D:/liuhuairiWorkSpace/Exercise/0826TestCenter/mctp-modules-template-base/node_modules/vite-plugin-svg-icons/dist/index.mjs";
import { defineConfig } from "file:///D:/liuhuairiWorkSpace/Exercise/0826TestCenter/mctp-modules-template-base/node_modules/vite/dist/node/index.js";
import vue from "file:///D:/liuhuairiWorkSpace/Exercise/0826TestCenter/mctp-modules-template-base/node_modules/@vitejs/plugin-vue/dist/index.mjs";
import AutoImport from "file:///D:/liuhuairiWorkSpace/Exercise/0826TestCenter/mctp-modules-template-base/node_modules/unplugin-auto-import/dist/vite.js";
import Icons from "file:///D:/liuhuairiWorkSpace/Exercise/0826TestCenter/mctp-modules-template-base/node_modules/unplugin-icons/dist/vite.js";
import IconsResolver from "file:///D:/liuhuairiWorkSpace/Exercise/0826TestCenter/mctp-modules-template-base/node_modules/unplugin-icons/dist/resolver.js";
import Components from "file:///D:/liuhuairiWorkSpace/Exercise/0826TestCenter/mctp-modules-template-base/node_modules/unplugin-vue-components/dist/vite.js";
import { ElementPlusResolver } from "file:///D:/liuhuairiWorkSpace/Exercise/0826TestCenter/mctp-modules-template-base/node_modules/unplugin-vue-components/dist/resolvers.js";
import path from "path";
import federation from "file:///D:/liuhuairiWorkSpace/Exercise/0826TestCenter/mctp-modules-template-base/node_modules/@originjs/vite-plugin-federation/dist/index.mjs";
var __vite_injected_original_import_meta_url = "file:///D:/liuhuairiWorkSpace/Exercise/0826TestCenter/mctp-modules-template-base/modules/module-test/vite.config.ts";
var vite_config_default = defineConfig({
  plugins: [
    vue(),
    federation({
      name: "testModule",
      // 修正为testModule，与平台端的remotes配置匹配
      filename: "moduleEntry.js",
      remotes: {
        hostModule: "http://localhost:3000/assets/hostEntry.js"
      },
      exposes: {
        "./main": "./src/index.ts"
      },
      shared: {
        vue: {
          import: false,
          // 插件端不主动导入，复用平台
          shareScope: "default",
          version: "^3.5.20"
        },
        pinia: {
          import: false,
          shareScope: "default",
          version: "^2.3.1"
        },
        "element-plus": {
          import: false,
          shareScope: "default",
          version: "^2.11.1"
        },
        "@element-plus/icons-vue": {
          import: false,
          shareScope: "default"
        }
      }
    }),
    // dts({
    //   include: ['src/**/*.ts', 'src/**/*.d.ts', 'src/**/*.vue'],
    //   // 使用配置的输出目录
    //   outDir: moduleConfig.getOutputDirectory(),
    //   staticImport: true,
    //   insertTypesEntry: true,
    //   cleanVueFileName: true,
    //   copyDtsFiles: true,
    // }),
    createSvgIconsPlugin({
      iconDirs: [path.resolve(process.cwd(), "src/assets/svg")],
      symbolId: "i-[dir]-[name]"
    }),
    AutoImport({
      resolvers: [
        IconsResolver({ prefix: "Icon" }),
        ElementPlusResolver()
      ]
    }),
    Components({
      resolvers: [
        IconsResolver({ enabledCollections: ["ep"] }),
        ElementPlusResolver()
      ]
    }),
    Icons({
      autoInstall: true,
      compiler: "vue3"
    })
  ],
  resolve: {
    alias: {
      "#/": fileURLToPath(new URL("./src", __vite_injected_original_import_meta_url))
    }
  },
  server: {
    port: 3003,
    cors: true
  },
  build: {
    outDir: "dist",
    emptyOutDir: true,
    target: ["es2022", "edge89", "firefox89", "chrome89", "safari15"],
    rollupOptions: {
      output: {
        assetFileNames: "assets/[name][extname]",
        entryFileNames: "assets/[name].js"
      }
    },
    minify: false,
    sourcemap: false
  }
});
export {
  vite_config_default as default
};
//# sourceMappingURL=data:application/json;base64,ewogICJ2ZXJzaW9uIjogMywKICAic291cmNlcyI6IFsidml0ZS5jb25maWcudHMiXSwKICAic291cmNlc0NvbnRlbnQiOiBbImNvbnN0IF9fdml0ZV9pbmplY3RlZF9vcmlnaW5hbF9kaXJuYW1lID0gXCJEOlxcXFxsaXVodWFpcmlXb3JrU3BhY2VcXFxcRXhlcmNpc2VcXFxcMDgyNlRlc3RDZW50ZXJcXFxcbWN0cC1tb2R1bGVzLXRlbXBsYXRlLWJhc2VcXFxcbW9kdWxlc1xcXFxtb2R1bGUtdGVzdFwiO2NvbnN0IF9fdml0Z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